500
|
How can I get the number of results after a filter is applied
![](images/exlistq500.png)
' Click event - Occurs when the user presses and then releases the left mouse button over the list control.
Private Sub Exlist1_Click(ByVal sender As System.Object) Handles Exlist1.Click
With Exlist1
.ClearFilter()
End With
End Sub
' FilterChange event - Occurs when filter was changed.
Private Sub Exlist1_FilterChange(ByVal sender As System.Object) Handles Exlist1.FilterChange
With Exlist1
Debug.Print( "Items.MatchItemCount" )
Debug.Print( .Items.MatchItemCount )
Debug.Print( .FormatABC("value < 0 ? `filter applied: ` + abs(value + 1) + ` result(s)` : `no filter`",.Items.MatchItemCount) )
End With
End Sub
With Exlist1
.BeginUpdate()
.Columns.Add("Item").DisplayFilterButton = True
With .Columns.Add("Pos")
.AllowSizing = False
.AllowSort = False
.Width = 32
.FormatColumn = "1 apos ``"
.Position = 0
End With
With .Items
.Add("Item A")
.Add("Item B")
.Add("Item C")
End With
.FilterBarPromptVisible = exontrol.EXLISTLib.FilterBarVisibleEnum.exFilterBarPromptVisible
.FilterBarPromptPattern = "Item"
.EndUpdate()
End With
|
499
|
How can I programmatically clear the control's filter
' Click event - Occurs when the user presses and then releases the left mouse button over the list control.
Private Sub Exlist1_Click(ByVal sender As System.Object) Handles Exlist1.Click
With Exlist1
.ClearFilter()
End With
End Sub
With Exlist1
.BeginUpdate()
.Columns.Add("Item").DisplayFilterButton = True
With .Columns.Add("Pos")
.AllowSizing = False
.AllowSort = False
.Width = 32
.FormatColumn = "1 apos ``"
.Position = 0
End With
With .Items
.Add("Item A")
.Add("Item B")
.Add("Item C")
End With
.FilterBarPromptVisible = exontrol.EXLISTLib.FilterBarVisibleEnum.exFilterBarPromptVisible
.FilterBarPromptPattern = "B"
.EndUpdate()
End With
|
498
|
Is it possible to prevent closing the control's filter bar, so it is always shown (prompt-combined)
![](images/exlistq498.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Item").DisplayFilterButton = True
With .Columns.Add("Pos")
.AllowSizing = False
.AllowSort = False
.Width = 32
.FormatColumn = "1 apos ``"
.Position = 0
End With
With .Items
.Add("Item A")
.Add("Item B")
.Add("Item C")
End With
.FilterBarPromptPattern = "B"
.FilterBarPromptVisible = exontrol.EXLISTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXLISTLib.FilterBarVisibleEnum.exFilterBarPromptVisible
With .Columns.Item(0)
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exFilter
.Filter = "Item B"
End With
.ApplyFilter()
.EndUpdate()
End With
|
497
|
Is it possible to prevent closing the control's filter bar, so it is always shown (prompt)
![](images/exlistq497.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Item").DisplayFilterButton = True
With .Columns.Add("Pos")
.AllowSizing = False
.AllowSort = False
.Width = 32
.FormatColumn = "1 apos ``"
.Position = 0
End With
With .Items
.Add("Item A")
.Add("Item B")
.Add("Item C")
End With
.FilterBarPromptVisible = exontrol.EXLISTLib.FilterBarVisibleEnum.exFilterBarPromptVisible
.FilterBarPromptPattern = "B"
.EndUpdate()
End With
|
496
|
Is it possible to prevent closing the control's filter bar, so it is always shown
![](images/exlistq496.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Item").DisplayFilterButton = True
With .Columns.Add("Pos")
.AllowSizing = False
.AllowSort = False
.Width = 32
.FormatColumn = "1 apos ``"
.Position = 0
End With
With .Items
.Add("Item A")
.Add("Item B")
.Add("Item C")
End With
.FilterBarCaption = "len(value) = 0 ? `<fgcolor=808080>no filter` : value"
.FilterBarPromptVisible = exontrol.EXLISTLib.FilterBarVisibleEnum.exFilterBarVisible
With .Columns.Item(0)
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exFilter
.Filter = "Item B"
End With
.ApplyFilter()
.EndUpdate()
End With
|
495
|
How can I find if the control is running in DPI mode
With Exlist1
Debug.Print( .FormatABC("dpi = 1 ? `normal/stretch mode` : `dpi mode`") )
End With
|
494
|
I am using single selection, the question is if possible to select an item only when the user releases the mouse, as currently it selects the item as soon as the user clicks it
' SelectionChanged event - Fired after a new item is selected.
Private Sub Exlist1_SelectionChanged(ByVal sender As System.Object) Handles Exlist1.SelectionChanged
With Exlist1
Debug.Print( "SelectionChanged" )
End With
End Sub
With Exlist1
.BeginUpdate()
.FreezeEvents(True)
.SingleSel = True
.SelectOnRelease = True
.Columns.Add("Column").FormatColumn = "1 apos `A-Z`"
With .Items
.Add("")
.set_SelectItem(.Add(""),True)
.Add("")
End With
.FreezeEvents(False)
.EndUpdate()
End With
|
493
|
Is it possible to select nothing
' SelectionChanged event - Fired after a new item is selected.
Private Sub Exlist1_SelectionChanged(ByVal sender As System.Object) Handles Exlist1.SelectionChanged
With Exlist1
Debug.Print( "SelectionChanged" )
End With
End Sub
With Exlist1
.BeginUpdate()
.FreezeEvents(True)
.AllowSelectNothing = True
.Columns.Add("Column").FormatColumn = "1 apos `A-Z`"
With .Items
.Add("")
.set_SelectItem(.Add(""),True)
.Add("")
End With
.FreezeEvents(False)
.EndUpdate()
End With
|
492
|
How do I change the drop down filter icon/button (black)
![](images/exlistq492.png)
With Exlist1
.BeginUpdate()
With .VisualAppearance
.Add(1,"gBFLBCJwBAEHhEJAAEhABXUIQAAYAQGKIcBiAKBQAGYBIJDEMgzDDAUBjKKocQTC4AIQjCK4JDKHYJRpHEZyCA8EhqGASRAFUQBYiWE4oSpLABQaK0ZwIGyRIrkGQgQ" & _
"gmPYDSDNU4zVIEEglBI0TDNczhNDENgtGYaJqHIYpZBcM40TKkEZoSIITZcRrOEBiRL1S0RBhGcRUHZlWzdN64LhuK47UrWdD/XhdVzXRbjfz1Oq+bxve48Br7A5yYTh" & _
"dr4LhOFQ3RjIL4xbIcUwGe6VZhjOLZXjmO49T69HTtOCYBEBA")
End With
.set_Background32(exontrol.EXLISTLib.BackgroundPartEnum.exCursorHoverColumn,-1)
.set_Background32(exontrol.EXLISTLib.BackgroundPartEnum.exHeaderFilterBarButton,&H1000000)
.set_Background(exontrol.EXLISTLib.BackgroundPartEnum.exBackColorFilter,Color.FromArgb(0,0,1))
.set_Background(exontrol.EXLISTLib.BackgroundPartEnum.exForeColorFilter,Color.FromArgb(255,255,255))
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarExclude,"<bgcolor 0><fgcolor ffffff> Exclude </fgcolor></bgcolor>")
.HeaderAppearance = exontrol.EXLISTLib.AppearanceEnum.None2
.BackColorHeader = Color.FromArgb(0,0,0)
.ForeColorHeader = Color.FromArgb(255,255,255)
.HeaderVisible = True
.BackColorLevelHeader = .BackColor
With .Columns.Add("Filter")
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowExclude Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
.DisplayFilterButton = True
.AllowSort = False
.AllowDragging = False
End With
With .Items
.Add("One")
.Add("Two")
.Add("Three")
End With
.EndUpdate()
End With
|
491
|
How do I change the drop down filter icon/button (white)
![](images/exlistq491.png)
With Exlist1
.BeginUpdate()
With .VisualAppearance
.Add(2,"gBFLBCJwBAEHhEJAAEhABX8GACAADACAxSDEMQBQKAAzQFAYbhgHCGAAGQaBUgmFgAQhFcZQSKUOQTDKNYykCIRSDUJYkSZEIyjBI8ExXFqNACkGKwYgmNYiTLAcgAN" & _
"J0WBaGIZJ4gOT5fDKMoEDRRYADFCscwxJybQAqGQKKb+VgAVY/cTyBIAEQSKA0TDOQ5TSKWB4JPZQRBEbZMNBtBIUJquKaqShdQJCU5FdY3Xblez9P7AMBwLFEC4NQ8Y" & _
"NYuPhjR4dRTIMhvVAsUArFh8Zg9GZZFjmDIDT4ydBLTQwcyVIKnP5qOa6XbmPoCQDYKxZHYxPzVDa3axuL76dqCAT7XrXNy1TbNRrzQKfcJqfCbdw2YaDZLOOT3fjuI4" & _
"hhKaRzFAHJ+jYQ4xHuY4gHuGIXGeExqC8Tp6C+PoEm+G5ImycRgh0XwvDGa5rgOeoejyXwnFeQp2mkf5ClgBB9gCWIYAwfYAEKV58mkdwOggNArgOXY2EWLoDkKOA0mg" & _
"bhOGgZApgaSBIHWSYHSmbApgYThmESZYJkIeIkgeCpfliLIHgpMIcmUYYYmODAlg2SI4mWfRfGOEguDcCRjFYAJihCQhJBSDoRmONgKEcI4kFCEJhhOVYTmYnAlEAQhW" & _
"BMJYJGYWoWmWSR2F6F5lnkWAQhUAgpEieRWEuSYkjWGpmkmNhuhuZwJkYcocmaaYkjyEhngnUA6lEFAlAEgI=")
.Add(1,"CP:2 -14 -4 -2 4")
End With
.set_Background32(exontrol.EXLISTLib.BackgroundPartEnum.exHeaderFilterBarButton,&H1000000)
.set_Background(exontrol.EXLISTLib.BackgroundPartEnum.exCursorHoverColumn,.BackColor)
.HeaderAppearance = exontrol.EXLISTLib.AppearanceEnum.None2
.BackColorHeader = Color.FromArgb(255,255,255)
.HeaderVisible = True
.HeaderHeight = 24
.BackColorLevelHeader = .BackColor
With .Columns.Add("Filter")
.DisplayFilterButton = True
.AllowSort = False
.AllowDragging = False
End With
.EndUpdate()
End With
|
490
|
Can I display the column's multiple-lines caption vertically oriented (method 2)
![](images/exlistq490.png)
With Exlist1
.BeginUpdate()
.HeaderHeight = 48
.ColumnAutoResize = True
With .Columns
.Add("And others ...")
With .Add("")
.HTMLCaption = "First Column"
.HeaderVertical = True
.Width = 36
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,8)
.Position = 0
End With
With .Add("")
.HTMLCaption = "<c><b>Second Column"
.HeaderVertical = True
.Width = 36
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,8)
.Position = 1
End With
With .Add("")
.HTMLCaption = "<r>Third Column"
.HeaderVertical = True
.Width = 36
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,8)
.Position = 2
End With
End With
With .Items
.set_CellState(.Add("Item 1"),3,1)
.set_CellState(.Add("Item 2"),2,1)
.set_CellState(.Add("Item 3"),1,1)
End With
.EndUpdate()
End With
|
489
|
Can I display the column's multiple-lines caption vertically oriented (method 1)
![](images/exlistq489.png)
With Exlist1
.BeginUpdate()
.HeaderHeight = 48
.HeaderSingleLine = False
.ColumnAutoResize = True
With .Columns
.Add("And others ...")
With .Add("First Column")
.HeaderVertical = True
.Width = 36
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,8)
.Position = 0
End With
With .Add("Second Column")
.HeaderBold = True
.HeaderVertical = True
.Width = 36
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,8)
.Position = 1
End With
With .Add("Third Column")
.HeaderVertical = True
.Width = 36
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,8)
.Position = 2
End With
End With
With .Items
.set_CellState(.Add("Item 1"),3,1)
.set_CellState(.Add("Item 2"),2,1)
.set_CellState(.Add("Item 3"),1,1)
End With
.EndUpdate()
End With
|
488
|
Can I display the column's caption vertically oriented (method 2)
![](images/exlistq488.png)
With Exlist1
.BeginUpdate()
.HeaderHeight = 48
.ColumnAutoResize = True
With .Columns
.Add("And others ...")
With .Add("")
.HTMLCaption = "First"
.HeaderVertical = True
.Width = 20
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Position = 0
End With
With .Add("")
.HTMLCaption = "<c><b>Second"
.HeaderVertical = True
.Width = 20
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Position = 1
End With
With .Add("")
.HTMLCaption = "<r>Third"
.HeaderVertical = True
.Width = 20
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Position = 2
End With
End With
With .Items
.set_CellState(.Add("Item 1"),3,1)
.set_CellState(.Add("Item 2"),2,1)
.set_CellState(.Add("Item 3"),1,1)
End With
.EndUpdate()
End With
|
487
|
Can I display the column's caption vertically oriented (method 1)
![](images/exlistq487.png)
With Exlist1
.BeginUpdate()
.HeaderHeight = 48
.ColumnAutoResize = True
With .Columns
.Add("And others ...")
With .Add("First")
.HeaderVertical = True
.Width = 20
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Position = 0
End With
With .Add("Second")
.HeaderBold = True
.HeaderVertical = True
.Width = 20
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Position = 1
End With
With .Add("Third")
.HeaderVertical = True
.Width = 20
.AllowSizing = False
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Position = 2
End With
End With
With .Items
.set_CellState(.Add("Item 1"),3,1)
.set_CellState(.Add("Item 2"),2,1)
.set_CellState(.Add("Item 3"),1,1)
End With
.EndUpdate()
End With
|
486
|
How do I get sorted the column as string, numeric, date, date and time. Also how can it be applied to drop down filter panel
![](images/exlistq486.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Date")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortDate
.DisplayFilterButton = True
.DisplayFilterPattern = False
.DisplayFilterDate = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exSortItemsDesc
End With
With .Columns.Add("DateTime")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortDateTime
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exSortItemsDesc
End With
With .Columns.Add("Time")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortTime
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exSortItemsDesc
.FormatColumn = "time(value)"
End With
With .Columns.Add("Numeric")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortNumeric
.DisplayFilterButton = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exSortItemsDesc
End With
With .Columns.Add("String")
.DisplayFilterButton = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exSortItemsDesc
End With
With .Items
h = .Add(#1/27/2010#)
.set_Caption(h,1,#1/27/2010 10:00:00 AM#)
.set_Caption(h,2,.get_Caption(h,1))
.set_Caption(h,3,1)
.set_Caption(h,4,.get_Caption(h,3))
h = .Add(#1/27/2011#)
.set_Caption(h,1,#1/27/2011 9:00:00 AM#)
.set_Caption(h,2,.get_Caption(h,1))
.set_Caption(h,3,11)
.set_Caption(h,4,.get_Caption(h,3))
h = .Add(#11/2/2010#)
.set_Caption(h,1,#11/2/2010 9:00:00 AM#)
.set_Caption(h,2,.get_Caption(h,1))
.set_Caption(h,3,2)
.set_Caption(h,4,.get_Caption(h,3))
End With
.Columns.Item("DateTime").DisplayFilterDate = False
.EndUpdate()
End With
|
485
|
How can I get ride / hide the image being dragged by OLE Drag and Drop
// OLEStartDrag event is not supported. Use the DragEnter,DragLeave,DragOver, DragDrop ... events.
With Exlist1
.OLEDropMode = exontrol.EXLISTLib.exOLEDropModeEnum.exOLEDropManual
.set_Background(exontrol.EXLISTLib.BackgroundPartEnum.exDragDropAfter,Color.FromArgb(255,255,255))
.Columns.Add("Default")
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
End With
End With
|
484
|
Is there an event that fires on the exList control when the order of items in the list is changed via dragging
' AllowAutoDrag event - Occurs when the user drags the item between InsertA and InsertB.
Private Sub Exlist1_AllowAutoDrag(ByVal sender As System.Object,ByVal Item As Integer,ByVal InsertA As Integer,ByVal InsertB As Integer,ByRef Cancel As Boolean) Handles Exlist1.AllowAutoDrag
With Exlist1
With .Items
Debug.Print( "After" )
Debug.Print( .get_Caption(InsertA,0) )
Debug.Print( "Before" )
Debug.Print( .get_Caption(InsertB,0) )
End With
Cancel = True
End With
End Sub
With Exlist1
.BeginUpdate()
.AutoDrag = exontrol.EXLISTLib.AutoDragEnum.exAutoDragPosition
.Columns.Add("Task")
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
.Add("Item 4")
End With
.EndUpdate()
End With
|
483
|
How can I export checked items only
![](images/exlistq483.png)
With Exlist1
.BeginUpdate()
With .Columns
.Add("C1").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Add("C2").FormatColumn = "1 index `A-Z`"
.Add("C3").FormatColumn = "100 index ``"
End With
With .Items
.Add("Item 1")
.set_CellState(.Add("Item 2"),0,1)
.set_CellState(.Add("Item 3"),0,1)
End With
.EndUpdate()
Debug.Print( "Export CSV Checked Items Only:" )
Debug.Print( .Export("","chk") )
End With
|
482
|
How can I export a hidden column
![](images/exlistq482.png)
With Exlist1
.BeginUpdate()
With .Columns
.Add("C1")
With .Add("C2")
.FormatColumn = "1 index `A-Z`"
.Visible = False
End With
With .Add("C3")
.FormatColumn = "100 index ``"
.Visible = False
End With
End With
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
End With
.EndUpdate()
Debug.Print( "Export CSV Hidden Columns (1,2):" )
Debug.Print( .Export("","|1,2") )
End With
|
481
|
Is it possible to have a different alignment for parts of the cell's caption
![](images/exlistq481.png)
Dim h
With Exlist1
.BeginUpdate()
.DrawGridLines = exontrol.EXLISTLib.GridLinesEnum.exAllLines
With .Columns.Add("Default")
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
End With
With .Items
.set_CellHAlignment(.Add("all-left"),0,exontrol.EXLISTLib.AlignmentEnum.LeftAlignment)
.set_CellHAlignment(.Add("all-center"),0,exontrol.EXLISTLib.AlignmentEnum.CenterAlignment)
.set_CellHAlignment(.Add("all-right"),0,exontrol.EXLISTLib.AlignmentEnum.RightAlignment)
h = .Add("left<c>center<r>right")
.set_CaptionFormat(h,0,exontrol.EXLISTLib.CaptionFormatEnum.exHTML)
End With
.EndUpdate()
End With
|
480
|
I have a column with Def(exCellSingleLine) property on False, word-wrapping, and I am wondering if possible to update the column's content while user is resizing it
With Exlist1
.BeginUpdate()
With .Columns
With .Add("MultipleLine")
.Width = 32
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellSingleLine,False)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exColumnResizeContiguously,True)
End With
With .Add("SingleLine")
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellSingleLine,False)
End With
End With
With .Items
.set_Caption(.Add("This is a bit of long text that should break the line"),1,"This is a bit of long text that should break the line")
End With
.EndUpdate()
End With
|
479
|
How can I hide the cell's tooltip
' ToolTip event - Fired when the control prepares the object's tooltip.
Private Sub Exlist1_ToolTip(ByVal sender As System.Object,ByVal ItemIndex As Integer,ByVal ColIndex As Integer,ByRef Visible As Boolean,ByRef X As Integer,ByRef Y As Integer,ByVal CX As Integer,ByVal CY As Integer) Handles Exlist1.ToolTip
With Exlist1
Debug.Print( "The tooltip is about to be shown" )
Visible = False
End With
End Sub
With Exlist1
.BeginUpdate()
.Columns.Add("Def")
With .Items
.set_CellToolTip(.Add("Item 1"),0,"This is a bit of text that's shown when cursor hovers the item.")
.set_CellToolTip(.Add("Item 2"),0,"This is a bit of text that's shown when cursor hovers the item.")
.set_CellToolTip(.Add("Item 3"),0,"This is a bit of text that's shown when cursor hovers the item.")
End With
.EndUpdate()
End With
|
478
|
How can I find out if an item is selected or unselected
' MouseMove event - Occurs when the user moves the mouse.
Private Sub Exlist1_MouseMoveEvent(ByVal sender As System.Object,ByVal Button As Short,ByVal Shift As Short,ByVal X As Integer,ByVal Y As Integer) Handles Exlist1.MouseMoveEvent
Dim c,hit,i
With Exlist1
i = .get_ItemFromPoint(-1,-1,c,hit)
With .Items
Debug.Print( .get_SelectItem(i) )
End With
End With
End Sub
With Exlist1
.Columns.Add("Header")
With .Items
.Add("Item 1")
.set_SelectItem(.Add("Item 2"),True)
.Add("Item 3")
End With
End With
|
477
|
How do I sort the index column as numeric
![](images/exlistq477.png)
' AddItem event - Occurs after a new Item is inserted to Items collection.
Private Sub Exlist1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exlist1.AddItem
With Exlist1
With .Items
.set_CellData(Item,1,Item)
End With
End With
End Sub
With Exlist1
.BeginUpdate()
.DrawGridLines = exontrol.EXLISTLib.GridLinesEnum.exAllLines
.ColumnAutoResize = True
.ShowFocusRect = False
With .Columns.Add("Next")
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,4)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exHeaderPaddingLeft,4)
End With
With .Columns.Add("Index")
.AllowSizing = False
.Width = 48
.FormatColumn = "(((0 := (1 index ``)) mod 3) case ( default: ``; 0 : `<r><fgcolor=B0B0B0>`; 1: ``; 2 : `<c><fgcolor=808080>` )) + str(=:0)"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortUserData
.Position = 0
End With
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
.Add("Item 4")
.Add("Item 5")
.Add("Item 6")
.Add("Item 7")
.Add("Item 8")
.Add("Item 9")
.Add("Item 10")
End With
.EndUpdate()
End With
|
476
|
How can I put icons/images into buttons
![](images/exlistq476.png)
With Exlist1
.BeginUpdate()
.ColumnAutoResize = True
.Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _
"lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _
"0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _
"NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
With .Columns.Add("C+B")
.AllowSizing = False
.Width = 48
.FormatColumn = "` <img>` + ( 1 + (1 index ``) mod 3 ) + `</img> `"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasButton,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasButton Or exontrol.EXLISTLib.DefColumnEnum.exCellHasRadioButton,True)
End With
.Columns.Add("")
.DrawGridLines = exontrol.EXLISTLib.GridLinesEnum.exVLines
.DefaultItemHeight = 20
With .Items
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
End With
.EndUpdate()
End With
|
475
|
Is it possible to have a CheckBox and Button TOGETHER on all cells in a column
![](images/exlistq475.png)
' CellButtonClick event - Fired after the user clicks the cell's button.
Private Sub Exlist1_CellButtonClick(ByVal sender As System.Object,ByVal Item As Integer,ByVal ColIndex As Integer) Handles Exlist1.CellButtonClick
With Exlist1
Debug.Print( "CellButtonClick" )
Debug.Print( Item )
End With
End Sub
' CellStateChanged event - Fired after cell's state is changed.
Private Sub Exlist1_CellStateChanged(ByVal sender As System.Object,ByVal Item As Integer,ByVal ColIndex As Integer) Handles Exlist1.CellStateChanged
With Exlist1
Debug.Print( "CellStateChanged" )
Debug.Print( Item )
End With
End Sub
With Exlist1
.BeginUpdate()
.ColumnAutoResize = True
With .Columns.Add("")
.AllowSizing = False
.Width = 32
.FormatColumn = "1 index ``"
End With
With .Columns.Add("Def")
.AllowSizing = False
.Width = 48
.FormatColumn = "` `"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasButton,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasButton Or exontrol.EXLISTLib.DefColumnEnum.exCellHasRadioButton,True)
End With
.Columns.Add("")
With .Items
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
.Add("")
End With
.EndUpdate()
End With
|
474
|
Does filtering work with umlauts / accents characters
With Exlist1
.BeginUpdate()
With .Columns.Add("Names")
.DisplayFilterButton = True
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exPattern
End With
With .Items
.Add("Mantel")
.Add("Mechanik")
.Add("Motor")
.Add("Murks")
.Add("Märchen")
.Add("Möhren")
.Add("Mühle")
.Add("Sérigraphie")
End With
.Columns.Item(0).Filter = "*ä*"
.ApplyFilter()
.EndUpdate()
End With
|
473
|
Can I set the search box / filterbarprompt to invisible, so I can use my own input and *string* via VBA
Dim h0
With Exlist1
.BeginUpdate()
.ColumnAutoResize = True
.ContinueColumnScroll = False
.MarkSearchColumn = False
.SearchColumnIndex = 1
.FilterBarHeight = 0
.FilterBarPromptVisible = True
With .Columns
.Add("Name").Width = 96
.Add("Title").Width = 96
.Add("City")
End With
With .Items
h0 = .Add("Nancy Davolio")
.set_Caption(h0,1,"Sales Representative")
.set_Caption(h0,2,"Seattle")
h0 = .Add("Andrew Fuller")
.set_Caption(h0,1,"Vice President, Sales")
.set_Caption(h0,2,"Tacoma")
.set_SelectItem(h0,True)
h0 = .Add("Janet Leverling")
.set_Caption(h0,1,"Sales Representative")
.set_Caption(h0,2,"Kirkland")
h0 = .Add("Margaret Peacock")
.set_Caption(h0,1,"Sales Representative")
.set_Caption(h0,2,"Redmond")
h0 = .Add("Steven Buchanan")
.set_Caption(h0,1,"Sales Manager")
.set_Caption(h0,2,"London")
h0 = .Add("Michael Suyama")
.set_Caption(h0,1,"Sales Representative")
.set_Caption(h0,2,"London")
h0 = .Add("Robert King")
.set_Caption(h0,1,"Sales Representative")
.set_Caption(h0,2,"London")
h0 = .Add("Laura Callahan")
.set_Caption(h0,1,"Inside Sales Coordinator")
.set_Caption(h0,2,"Seattle")
h0 = .Add("Anne Dodsworth")
.set_Caption(h0,1,"Sales Representative")
.set_Caption(h0,2,"London")
End With
.FilterBarPromptPattern = "London"
.EndUpdate()
End With
|
472
|
How can I align captions of items with checkbox, with items with no checkbox
![](images/exlistq472.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Default")
With .Items
.set_CellImages(.Add(0),0,"1")
.set_CellHasCheckBox(.Add(1),0,True)
.set_CellImages(.Add(2),0,"1")
End With
.EndUpdate()
End With
|
471
|
How do I programmatically scroll the control (method 2)
Dim rs
With Exlist1
.BeginUpdate()
.ColumnAutoResize = False
.ContinueColumnScroll = False
rs = New ADODB.Recordset()
With rs
.Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExList\Sample\Access\SAMPLE.ACCDB",3,3)
End With
.DataSource = rs
.Layout = "vscroll = 10"
.EndUpdate()
End With
|
470
|
How do I programmatically scroll the control (method 1)
Dim rs
With Exlist1
.BeginUpdate()
.ColumnAutoResize = False
.ContinueColumnScroll = False
rs = New ADODB.Recordset()
With rs
.Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExList\Sample\Access\SAMPLE.ACCDB",3,3)
End With
.DataSource = rs
.set_ScrollPos(True,10)
.EndUpdate()
End With
|
469
|
How can I decode the Layout property
With Exlist1
.BeginUpdate()
With .Columns
.Add("C1")
.Add("C2").Position = 1
End With
With .Items
.set_Caption(.Add("SubItem 1.1"),1,"SubItem 1.2")
.set_Caption(.Add("SubItem 2.1"),1,"SubItem 2.2")
End With
.Columns.Item("C2").SortOrder = exontrol.EXLISTLib.SortOrderEnum.SortDescending
.EndUpdate()
Debug.Print( "Encoded:" )
Debug.Print( .Layout )
' Add 'exontrol.exprint.dll(ExPrint.dll)' reference to your project.
With New exontrol.EXPRINTLib.exprint()
Debug.Print( "Decoded: " )
Debug.Print( .get_Decode64TextW(Exlist1.Layout) )
End With
End With
|
468
|
Does the title of the cell's tooltip supports HTML format
![](images/exlistq468.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("")
.Caption = ""
.HTMLCaption = "Column"
End With
With .Items
h = .Add("tooltip w/h different title")
.set_CellToolTip(h,0,"<c><b><fgcolor=FF0000>Title</fgcolor></b><br>This is bit of text that's shown when the user hovers the cell. This shows the tit" & _
"le centered with a different color.")
End With
.EndUpdate()
End With
|
467
|
How do I specify a different title for the cell's tooltip
![](images/exlistq467.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("")
.Caption = "This is the title"
.HTMLCaption = "Column"
End With
With .Items
h = .Add("tooltip w/h different title")
.set_CellToolTip(h,0,"This is bit of text that's shown when the user hovers the cell.")
End With
.EndUpdate()
End With
|
466
|
The cell's tooltip displays the column's caption in its title. How can I get ride of that
![](images/exlistq466.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns
.Add("C1")
.Add("C2")
End With
With .Items
h = .Add("tooltip w/h caption")
.set_CellToolTip(h,0,"This is bit of text that's shown when the user hovers the cell. This shows the column's caption in the title.")
.set_Caption(h,1,"tooltip no caption")
.set_CellToolTip(h,1,"This is bit of text that's shown when the user hovers the cell. This shows no column's caption in the title.")
End With
With .Columns.Item("C2")
.HTMLCaption = .Caption
.Caption = ""
End With
.EndUpdate()
End With
|
465
|
When you click the cell it takes some time before the edit box appears, can this delay be removed
![](images/exlistq465.png)
' Click event - Occurs when the user presses and then releases the left mouse button over the list control.
Private Sub Exlist1_Click(ByVal sender As System.Object) Handles Exlist1.Click
Dim ColIndex,HitTestInfo,h
With Exlist1
h = .get_ItemFromPoint(-1,-1,ColIndex,HitTestInfo)
.Items.Edit(h,ColIndex)
End With
End Sub
With Exlist1
.AllowEdit = True
.Columns.Add("Default")
With .Items
.Add("")
.Add("Edit")
.Add("")
End With
End With
|
464
|
How can I programmatically show the column's filter
![](images/exlistq464.png)
' RClick event - Fired when right mouse button is clicked
Private Sub Exlist1_RClick(ByVal sender As System.Object) Handles Exlist1.RClick
Dim c,hit,i
With Exlist1
i = .get_ItemFromPoint(-1,-1,c,hit)
.Columns.Item(c).ShowFilter("-1,-1,128,128")
End With
End Sub
With Exlist1
.BeginUpdate()
.ShowFocusRect = False
With .Columns.Add("Items ")
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowExclude Or exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
End With
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
End With
.EndUpdate()
End With
|
463
|
I want to be able to click on one of the headers, and sort by other column. How can I do that
![](images/exlistq463.png)
' ColumnClick event - Fired after the user clicks on column's header.
Private Sub Exlist1_ColumnClick(ByVal sender As System.Object,ByVal Column As exontrol.EXLISTLib.Column) Handles Exlist1.ColumnClick
' Column.SortOrder = 1
With Exlist1
.SortOnClick = exontrol.EXLISTLib.SortOnClickEnum.exDefaultSort
.Columns.Item("Sort").SortOrder = exontrol.EXLISTLib.SortOrderEnum.SortAscending
.SortOnClick = exontrol.EXLISTLib.SortOnClickEnum.exUserSort
End With
End Sub
With Exlist1
.BeginUpdate()
.SortOnClick = exontrol.EXLISTLib.SortOnClickEnum.exUserSort
.Columns.Add("Items")
.Columns.Add("Sort").Visible = False
With .Items
.set_Caption(.Add("Item 1 (3)"),1,3)
.set_Caption(.Add("Item 2 (1)"),1,1)
.set_Caption(.Add("Item 3 (2)"),1,2)
End With
.EndUpdate()
End With
|
462
|
How can I sort by two-columns, one by date and one by time
![](images/exlistq462.png)
Dim h
With Exlist1
.BeginUpdate()
.SingleSort = False
With .Columns
.Add("Index").FormatColumn = "1 index ``"
.Add("Date").SortType = exontrol.EXLISTLib.SortTypeEnum.SortDate
With .Add("Time")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortTime
.FormatColumn = "time(value)"
End With
End With
With .Items
h = .Add(0)
.set_Caption(h,1,#1/1/2001#)
.set_Caption(h,2,#1/1/2001 10:00:00 AM#)
h = .Add(0)
.set_Caption(h,1,#12/31/2000#)
.set_Caption(h,2,#1/1/2001 10:00:00 AM#)
h = .Add(0)
.set_Caption(h,1,#1/1/2001#)
.set_Caption(h,2,#1/1/2001 6:00:00 AM#)
h = .Add(0)
.set_Caption(h,1,#12/31/2000#)
.set_Caption(h,2,#1/1/2001 8:00:00 AM#)
h = .Add(0)
.set_Caption(h,1,#1/1/2001#)
.set_Caption(h,2,#1/1/2001 8:00:00 AM#)
h = .Add(0)
.set_Caption(h,1,#12/31/2000#)
.set_Caption(h,2,#1/1/2001 6:00:00 AM#)
End With
.Layout = "multiplesort=""C1:1 C2:1"""
.EndUpdate()
End With
|
461
|
How can I connect to a DBF file
Dim rs
With Exlist1
.BeginUpdate()
.ColumnAutoResize = False
.ContinueColumnScroll = False
.MarkSearchColumn = False
rs = New ADODB.Recordset()
With rs
.Open("Select * From foxcode.DBF","Provider=vfpoledb;Data Source=C:\Program Files\Microsoft Visual FoxPro 9\",3,3)
End With
.DataSource = rs
.EndUpdate()
End With
|
460
|
Does your control supports scrolling by touching the screen
![](images/exlistq460.png)
Dim rs
With Exlist1
.ColumnAutoResize = False
rs = New ADODB.Recordset()
With rs
.Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExList\Sample\Access\SAMPLE.ACCDB",3,3)
End With
.DataSource = rs
.ContinueColumnScroll = True
.ScrollBySingleLine = True
.AutoDrag = exontrol.EXLISTLib.AutoDragEnum.exAutoDragScrollOnShortTouch Or exontrol.EXLISTLib.AutoDragEnum.exAutoDragScroll
End With
|
459
|
How can I enlarge the size of the control's scroll bars, for using on touch screens
![](images/exlistq459.png)
With Exlist1
.ScrollBars = exontrol.EXLISTLib.ScrollBarsEnum.DisableBoth
.ScrollWidth = 32
.ScrollHeight = 32
.ScrollButtonHeight = 32
.ScrollButtonWidth = 32
End With
|
458
|
Is there a syntax for conditional formatting of items, based on CellState/CellStateChange
![](images/exlistq458.png)
' CellStateChanged event - Fired after cell's state is changed.
Private Sub Exlist1_CellStateChanged(ByVal sender As System.Object,ByVal Item As Integer,ByVal ColIndex As Integer) Handles Exlist1.CellStateChanged
With Exlist1
With .Items
.set_Caption(Item,2,.get_CellState(Item,0))
End With
End With
End Sub
Dim h,var_ConditionalFormat
With Exlist1
.BeginUpdate()
.ShowFocusRect = False
.MarkSearchColumn = False
.SelBackMode = exontrol.EXLISTLib.BackModeEnum.exTransparent
var_ConditionalFormat = .ConditionalFormats.Add("%2 != 0")
With var_ConditionalFormat
.Bold = True
.ForeColor = Color.FromArgb(255,0,0)
.ApplyTo = exontrol.EXLISTLib.FormatApplyToEnum.exFormatToItems
End With
With .Columns.Add("")
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Width = 16
.AllowSizing = False
End With
.Columns.Add("Information")
.Columns.Add("Hidden").Visible = False
With .Items
.set_Caption(.Add(""),1,"This is a bit of text associated")
h = .Add("")
.set_Caption(h,1,"This is a bit of text associated")
.set_CellState(h,0,1)
.set_Caption(.Add(""),1,"This is a bit of text associated")
End With
.EndUpdate()
End With
|
457
|
How can I display the caption bellow to picture
![](images/exlistq457.png)
Dim h
With Exlist1
.BeginUpdate()
.ScrollBySingleLine = True
.set_HTMLPicture("p1","c:\exontrol\images\zipdisk.gif")
.set_HTMLPicture("p2","c:\exontrol\images\auction.gif")
.Columns.Add("Default")
With .Items
h = .Add("<c><img>p1</img><br><c>your caption1")
.set_CellSingleLine(h,0,exontrol.EXLISTLib.CellSingleLineEnum.exCaptionWordWrap)
.set_CaptionFormat(h,0,exontrol.EXLISTLib.CaptionFormatEnum.exHTML)
h = .Add("<c><img>p2</img><br><c>your caption2")
.set_CellSingleLine(h,0,exontrol.EXLISTLib.CellSingleLineEnum.exCaptionWordWrap)
.set_CaptionFormat(h,0,exontrol.EXLISTLib.CaptionFormatEnum.exHTML)
End With
.EndUpdate()
End With
|
456
|
How can I add a vertical padding
![](images/exlistq456.png)
With Exlist1
.BeginUpdate()
.DrawGridLines = exontrol.EXLISTLib.GridLinesEnum.exAllLines
With .Columns.Add("Padding")
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellSingleLine,False)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,6)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingRight,6)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingTop,6)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingBottom,6)
End With
With .Items
.Add("padding")
.Add("padding")
End With
.EndUpdate()
End With
|
455
|
How do you embed HTML options into the anchor click string
![](images/exlistq455.png)
' AnchorClick event - Occurs when an anchor element is clicked.
Private Sub Exlist1_AnchorClick(ByVal sender As System.Object,ByVal AnchorID As String,ByVal Options As String) Handles Exlist1.AnchorClick
With Exlist1
Debug.Print( AnchorID )
Debug.Print( Options )
End With
End Sub
With Exlist1
.BeginUpdate()
With .Columns
.Add("Car").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
End With
With .Items
.Add("<a mazda_1;options for 1>Mazda <b>1</b></a>")
.Add("<a mazda_2;options for 2>Mazda <b>2</b></a>")
.Add("<a mazda_3;options for 3a>Mazda <b>3.a</b></a>")
.Add("<a mazda_3;options for 3b>Mazda <b>3.b</b></a>")
End With
.EndUpdate()
End With
|
454
|
I have the rows with different background color, and when I select the item it takes the color of the SelBackColor, and therefore is no longer visible behind the color. Is there any option to make the item's color being visible (method 3)
![](images/exlistq454.png)
With Exlist1
.BeginUpdate()
.VisualAppearance.Add(1,"gBFLBCJwBAEHhEJAEGg4BVEIQAAYAQGKIYBkAKBQAGaAoDDMOQwQwAAxjGKEEwsACEIrjKCRShyCYZRhGcTSBCIZBqEqSZLiEZRQCWIAzATGYBRfIUEgjBM6ExwG78e" & _
"gBHp/ZpkACIJJAaRjHQdJxGKKMQB9DIhCZpeKhWgkKIJBzOEyBRC4ERBGqNGrsIgLEqWZpnWhaNpWXYTLyBN64LhuK46g53O6wLxvK6hEr2dJ/YBcIAOfghf4NQ7EMRx" & _
"LC8Mw3BDvYDkOAABAIgI=")
.SelBackColor32 = &H1fffffe
.ShowFocusRect = False
.Columns.Add("Items")
With .Items
.set_ItemBackColor(.Add("red"),Color.FromArgb(255,0,0))
.set_ItemBackColor(.Add("blue"),Color.FromArgb(0,0,255))
.set_ItemBackColor(.Add("green"),Color.FromArgb(0,255,0))
End With
.EndUpdate()
End With
|
453
|
I have the rows with different background color, and when I select the item it takes the color of the SelBackColor, and therefore is no longer visible behind the color. Is there any option to make the item's color being visible (method 2)
![](images/exlistq453.png)
With Exlist1
.BeginUpdate()
.SelBackMode = exontrol.EXLISTLib.BackModeEnum.exTransparent
.ShowFocusRect = False
.Columns.Add("Items")
With .Items
.set_ItemBackColor(.Add("red"),Color.FromArgb(255,0,0))
.set_ItemBackColor(.Add("blue"),Color.FromArgb(0,0,255))
.set_ItemBackColor(.Add("green"),Color.FromArgb(0,255,0))
End With
.EndUpdate()
End With
|
452
|
I have the rows with different background color, and when I select the item it takes the color of the SelBackColor, and therefore is no longer visible behind the color. Is there any option to make the item's color being visible (method 1)
![](images/exlistq452.png)
With Exlist1
.BeginUpdate()
.SelBackColor = .BackColor
.SelForeColor = .ForeColor
.ShowFocusRect = True
.Columns.Add("Items")
With .Items
.set_ItemBackColor(.Add("red"),Color.FromArgb(255,0,0))
.set_ItemBackColor(.Add("blue"),Color.FromArgb(0,0,255))
.set_ItemBackColor(.Add("green"),Color.FromArgb(0,255,0))
End With
.EndUpdate()
End With
|
451
|
I am using the FormatColumn property, but is it also possible to have a blank field when the value is '0'. I've tried the 'leading zero' flag in the FormatColumn, but that did not work
![](images/exlistq451.png)
With Exlist1
.Columns.Add("Currency").FormatColumn = "int(value) != 0 ? (value format `0||3|,`) : ``"
.Items.Add(123456789)
.Items.Add(1234)
.Items.Add(0)
.Items.Add(2345)
End With
|
450
|
Do you have a VB sample on how to use .FormatColumn to show this number '123456789' like '123,456,789'
![](images/exlistq450.png)
With Exlist1
.Columns.Add("Currency").FormatColumn = "value format `0||3|,`"
.Items.Add(123456789)
.Items.Add(1234)
End With
|
449
|
Is it possible to change the image while do OLE Drag and Drop operations
![](images/exlistq449.png)
// OLEStartDrag event is not supported. Use the DragEnter,DragLeave,DragOver, DragDrop ... events.
With Exlist1
.Columns.Add("Default")
.Items.Add("Item 1")
.Items.Add("Item 2")
.OLEDropMode = exontrol.EXLISTLib.exOLEDropModeEnum.exOLEDropManual
.set_HTMLPicture("OLEDragDropImage","C:\Program Files\Exontrol\ExList\Sample\VB\UNICODE\unicode.jpg")
End With
|
448
|
Is it possible to change the image while do OLE Drag and Drop operations
![](images/exlistq448.png)
// OLEStartDrag event is not supported. Use the DragEnter,DragLeave,DragOver, DragDrop ... events.
With Exlist1
.Columns.Add("Default")
.Items.Add("Item 1")
.Items.Add("Item 2")
.OLEDropMode = exontrol.EXLISTLib.exOLEDropModeEnum.exOLEDropManual
.VisualAppearance.Add(1,"C:\Program Files\Exontrol\ExG2antt\Sample\EBN\xpbselIcon.ebn")
.set_Background32(exontrol.EXLISTLib.BackgroundPartEnum.exDragDropAfter,&H1000000)
.set_Background(exontrol.EXLISTLib.BackgroundPartEnum.exDragDropBefore,Color.FromArgb(255,255,255))
End With
|
447
|
How can copy and paste the selection to Microsoft Word, any OLE compliant application, as a snapshot
With Exlist1
.BeginUpdate()
.VisualAppearance.Add(1,"c:\exontrol\images\normal.ebn")
.set_HTMLPicture("p1","c:\exontrol\images\card.png")
.set_HTMLPicture("p2","c:\exontrol\images\sun.png")
.AutoDrag = exontrol.EXLISTLib.AutoDragEnum.exAutoDragCopySnapShot
.ShowFocusRect = False
.DefaultItemHeight = 26
.Columns.Add("Task")
With .Items
.set_CaptionFormat(.Add("<img>p1:32</img> Group 1"),0,exontrol.EXLISTLib.CaptionFormatEnum.exHTML)
.set_CaptionFormat(.Add("<img>p2:32</img> Group 2"),0,exontrol.EXLISTLib.CaptionFormatEnum.exHTML)
End With
.EndUpdate()
End With
|
446
|
How can copy and paste the selection to Microsoft Word, any OLE compliant application, as a image
![](images/exlistq446.png)
Dim rs
With Exlist1
.BeginUpdate()
.set_HTMLPicture("p1","c:\exontrol\images\card.png")
.set_HTMLPicture("p2","c:\exontrol\images\sun.png")
.HeaderHeight = 24
.DefaultItemHeight = 48
.DrawGridLines = &Hfffffffc Or exontrol.EXLISTLib.GridLinesEnum.exVLines
.GridLineColor = Color.FromArgb(240,240,240)
.SelBackMode = exontrol.EXLISTLib.BackModeEnum.exTransparent
.ColumnAutoResize = False
.ContinueColumnScroll = False
rs = New ADODB.Recordset()
With rs
.Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExList\Sample\Access\SAMPLE.ACCDB",3,3)
End With
.DataSource = rs
.Columns.Item(0).set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
.Columns.Item(0).FormatColumn = "value + ` <img>p` + (1 + (value mod 3 ) ) + `</img>`"
.Columns.Item(0).Width = 112
.AutoDrag = exontrol.EXLISTLib.AutoDragEnum.exAutoDragCopyImage
.SingleSel = False
With .Items
.set_SelectItem(1,True)
.set_SelectItem(2,True)
.set_SelectItem(3,True)
End With
.EndUpdate()
End With
|
445
|
How can copy and paste the selection to Microsoft Word, Excel or any OLE compliant application, as a text
![](images/exlistq445.png)
Dim rs
With Exlist1
.BeginUpdate()
.ColumnAutoResize = False
.ContinueColumnScroll = False
rs = New ADODB.Recordset()
With rs
.Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExList\Sample\Access\SAMPLE.ACCDB",3,3)
End With
.DataSource = rs
.AutoDrag = exontrol.EXLISTLib.AutoDragEnum.exAutoDragCopyText
.SingleSel = False
With .Items
.set_SelectItem(1,True)
.set_SelectItem(3,True)
.set_SelectItem(4,True)
.set_SelectItem(5,True)
End With
.EndUpdate()
End With
|
444
|
How can I change the row's position to another, by drag and drop. Is it possible
![](images/exlistq444.png)
With Exlist1
.BeginUpdate()
.AutoDrag = exontrol.EXLISTLib.AutoDragEnum.exAutoDragPosition
.Columns.Add("Task")
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
.Add("Item 4")
End With
.EndUpdate()
End With
|
443
|
Does your control support subscript or superscript, in HTML captions
![](images/exlistq443.png)
With Exlist1
.Columns.Add("Column").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
.Items.Add("<sha ;;0>Event <b><font ;6><off -6>2<off 4>3<off 4>1")
End With
|
442
|
Is there any property I can save and restore automatically the current setting, column position, size, and so on (2)
![](images/exlistq442.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Column")
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
End With
.Layout = "Select=""0"";SingleSort=""C0:2"";Columns=1"
.EndUpdate()
End With
|
441
|
Is there any property I can save and restore automatically the current setting, column position, size, and so on (1)
![](images/exlistq441.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Column")
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
End With
.Layout = "gBjAAwAAuABmABpABsAB0ABlAByhoAPIAOEPAA9gYABoABQAgUEg0XN4AOcJicKkpujMbjsfkMFk0YhkQgUOjUEl8gjcGO0ok8KMULjEaGMcj08kQAO8oMkTNEtGwAG" & _
"QAqc7gUlhh1ABtAEsk9GpEfhElgVcsMupNlnlonlaAFcr0shUsp8QPEtnVJqJhmcIhUMh0QiU5sYAqMngUSuEMw07k8Qv0SgVRrNEuVflF2jF5x9JyNEm0TjQijemyE0" & _
"jE3t+YruauoAu4Az1qj9BzRn0UzksSnAA0xDjY6qnAw8OiUQ0dwzN0zWz2t7j8/xURAGNvWH6k8xlEhklhEI0O/6QAgI="
.EndUpdate()
End With
|
440
|
Is there any public method to export the selected data
![](images/exlistq440.png)
With Exlist1
.BeginUpdate()
With .Columns
.Add("C1")
.Add("C2").FormatColumn = "1 index `A-Z`"
.Add("C3").FormatColumn = "100 index ``"
End With
With .Items
.Add("Item 1")
.set_SelectItem(.Add("Item 2"),True)
.Add("Item 3")
End With
.EndUpdate()
Debug.Print( "Export CSV Selected Items Only:" )
Debug.Print( .Export("","sel") )
End With
|
439
|
How can I change the visual aspect of the links in the sort bar
![](images/exlistq439.png)
Dim rs
With Exlist1
.BeginUpdate()
.ColumnAutoResize = False
rs = New ADODB.Recordset()
With rs
.Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExList\Sample\Access\SAMPLE.ACCDB",3,3)
End With
.DataSource = rs
.SortBarHeight = 24
.HeaderHeight = 24
.BackColorSortBar = Color.FromArgb(240,240,240)
.BackColorSortBarCaption = .BackColor
.VisualAppearance.Add(1,"gBFLBCJwBAEHhEJAEGg4BdsIQAAYAQGKIYBkAKBQAGaAoDDgNw0QwAAxjMK0EwsACEIrjKCRShyCYZRhGcTSBCIZBqEqSZLiEZRQiiCYsS5GQBSFDcOwHGyQYDkCQpA" & _
"AWL4tCyMc7QHKAWhrEAbJjgQYJUh+TQAAZCIJRXRQAL/K6rKwnSCQIgkUBpGKdBynEYoYxAfyESCJWyIahWAwoQjUMB1HLQAAxC5kKbkIxyBABFBdVjVeBYG78Bz+ABj" & _
"EovbAMEwPBqAMwmIAZDheA4FR4AGhTXKcbxrFaXZSzKckPRoADSZq1Sg5LjDJI2ABqU6ABqNLZtJKsZS4apABrWeZ3Q7QMLdFTwA4PH6EZhxXAYbTVeaPZjQIBAgI")
.SortBarVisible = True
.SortBarCaption = "Drag a <b>column</b> header here to group by that column."
With .Columns.Item(1)
.Alignment = exontrol.EXLISTLib.AlignmentEnum.CenterAlignment
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellBackColor,15790320)
.SortOrder = True
End With
With .Columns.Item(5)
.Alignment = exontrol.EXLISTLib.AlignmentEnum.CenterAlignment
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellBackColor,16119285)
.SortOrder = True
End With
.set_Background32(exontrol.EXLISTLib.BackgroundPartEnum.exSortBarLinkColor,&H1000000)
.EndUpdate()
End With
|
438
|
How can I have a case-insensitive filter (exFilterDoCaseSensitive flag is not set)
![](images/exlistq438.png)
With Exlist1
.BeginUpdate()
.MarkSearchColumn = False
With .Columns
With .Add("Car")
.DisplayFilterButton = True
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exFilter
.Filter = "MAZDA"
End With
With .Add("Equipment")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.CustomFilter = "Air Bag||*Air Bag*|||Air condition||*Air condition*|||ABS||*ABS*|||ESP||*ESP*"
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exPattern
.Filter = "AIR BAG"
End With
End With
With .Items
.set_Caption(.Add("Mazda"),1,"Air Bag")
.set_Caption(.Add("Toyota"),1,"Air Bag,Air condition")
.set_Caption(.Add("Ford"),1,"Air condition")
.set_Caption(.Add("Nissan"),1,"Air Bag,ABS,ESP")
.set_Caption(.Add("Mazda"),1,"Air Bag, ABS,ESP")
.set_Caption(.Add("Mazda"),1,"ABS,ESP")
End With
.ApplyFilter()
.EndUpdate()
End With
|
437
|
How can I have a case-sensitive filter
![](images/exlistq437.png)
With Exlist1
.BeginUpdate()
.MarkSearchColumn = False
With .Columns
With .Add("Car")
.DisplayFilterButton = True
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exFilterDoCaseSensitive Or exontrol.EXLISTLib.FilterTypeEnum.exFilter
.Filter = "Mazda"
End With
With .Add("Equipment")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.CustomFilter = "Air Bag||*Air Bag*|||Air condition||*Air condition*|||ABS||*ABS*|||ESP||*ESP*"
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exFilterDoCaseSensitive Or exontrol.EXLISTLib.FilterTypeEnum.exPattern
.Filter = "Air Bag"
End With
End With
With .Items
.set_Caption(.Add("Mazda"),1,"Air Bag")
.set_Caption(.Add("Toyota"),1,"Air Bag,Air condition")
.set_Caption(.Add("Ford"),1,"Air condition")
.set_Caption(.Add("Nissan"),1,"Air Bag,ABS,ESP")
.set_Caption(.Add("Mazda"),1,"Air Bag, ABS,ESP")
.set_Caption(.Add("Mazda"),1,"ABS,ESP")
End With
.ApplyFilter()
.EndUpdate()
End With
|
436
|
I have several columns, but noticed that the filter is using AND between columns, but I need OR clause for filtering. Is it possible
![](images/exlistq436.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Item")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.Filter = "Child 1"
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exFilter
End With
With .Columns.Add("Date")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.DisplayFilterDate = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowExclude Or exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exNoItems
.Filter = #12/28/2010#
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exDate
End With
.FilterCriteria = "%0 or %1"
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarOr,"<font ;18><fgcolor=FF0000>or</fgcolor></font>")
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarAnd,"<font ;18><fgcolor=FF0000>and</fgcolor></font>")
With .Items
h = .Add("Root 1")
.set_Caption(.Add("Child 1"),1,#12/27/2010#)
.set_Caption(.Add("Child 2"),1,#12/28/2010#)
h = .Add("Root 2")
.set_Caption(.Add("Child 1"),1,#12/29/2010#)
.set_Caption(.Add("Child 2"),1,#12/30/2010#)
End With
.ApplyFilter()
.EndUpdate()
End With
|
435
|
Is it possible exclude the dates being selected in the drop down filter window
![](images/exlistq435.png)
With Exlist1
.BeginUpdate()
With .Columns.Add("Date")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortDate
.DisplayFilterButton = True
.DisplayFilterPattern = False
.DisplayFilterDate = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowExclude Or exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exNoItems
End With
With .Items
.Add(#12/27/2010#)
.Add(#12/28/2010#)
.Add(#12/29/2010#)
.Add(#12/30/2010#)
.Add(#12/31/2010#)
End With
.EndUpdate()
End With
|
434
|
How can I display a calendar control inside the drop down filter window
![](images/exlistq434.png)
With Exlist1
.BeginUpdate()
With .Columns.Add("Date")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortDate
.DisplayFilterButton = True
.DisplayFilterPattern = False
.DisplayFilterDate = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox Or exontrol.EXLISTLib.FilterListEnum.exNoItems
End With
With .Items
.Add(#12/27/2010#)
.Add(#12/28/2010#)
.Add(#12/29/2010#)
.Add(#12/30/2010#)
.Add(#12/31/2010#)
End With
.EndUpdate()
End With
|
433
|
Is it possible to include the dates as checkb-boxes in the drop down filter window
![](images/exlistq433.png)
With Exlist1
.BeginUpdate()
With .Columns.Add("Dates")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortDate
.DisplayFilterButton = True
.DisplayFilterPattern = True
.DisplayFilterDate = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
.Filter = "to 12/27/2010"
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exDate
End With
With .Items
.Add(#12/27/2010#)
.Add(#12/28/2010#)
.Add(#12/29/2010#)
.Add(#12/30/2010#)
.Add(#12/31/2010#)
End With
.ApplyFilter()
.EndUpdate()
End With
|
432
|
How can I filter items for dates before a specified date
![](images/exlistq432.png)
With Exlist1
.BeginUpdate()
With .Columns.Add("Dates")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortDate
.DisplayFilterButton = True
.DisplayFilterPattern = True
.DisplayFilterDate = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exNoItems
.Filter = "to 12/27/2010"
.FilterType = exontrol.EXLISTLib.FilterTypeEnum.exDate
End With
With .Items
.Add(#12/27/2010#)
.Add(#12/28/2010#)
.Add(#12/29/2010#)
.Add(#12/30/2010#)
.Add(#12/31/2010#)
End With
.ApplyFilter()
.EndUpdate()
End With
|
431
|
Is it possible to filter dates
![](images/exlistq431.png)
With Exlist1
.BeginUpdate()
With .Columns.Add("Dates")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortDate
.DisplayFilterButton = True
.DisplayFilterPattern = True
.DisplayFilterDate = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exNoItems
End With
With .Items
.Add(#12/27/2010#)
.Add(#12/28/2010#)
.Add(#12/29/2010#)
.Add(#12/30/2010#)
.Add(#12/31/2010#)
End With
.EndUpdate()
End With
|
430
|
Is it possible to change the Exclude field name to something different, in the drop down filter window
![](images/exlistq430.png)
Dim h
With Exlist1
.BeginUpdate()
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarExclude,"Leaving out")
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowExclude Or exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
End With
.EndUpdate()
End With
|
429
|
How can I display the Exclude field in the drop down filter window
![](images/exlistq429.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowExclude Or exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
End With
.EndUpdate()
End With
|
428
|
Is it possible to show and ensure the focused item from the control, in the drop down filter window
![](images/exlistq428.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowFocusItem Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
.set_SelectItem(.Add("Child 2"),True)
End With
.EndUpdate()
End With
|
427
|
Is it possible to show only blanks items with no listed items from the control
![](images/exlistq427.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowBlanks Or exontrol.EXLISTLib.FilterListEnum.exNoItems
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
.Add("Child 2")
End With
.EndUpdate()
End With
|
426
|
How can I include the blanks items in the drop down filter window
![](images/exlistq426.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowBlanks Or exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
.Add("Child 2")
End With
.EndUpdate()
End With
|
425
|
How can I select multiple items in the drop down filter window, using check-boxes
![](images/exlistq425.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exShowCheckBox
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
.Add("Child 2")
End With
.EndUpdate()
End With
|
424
|
Is it possible to allow a single item being selected in the drop down filter window
![](images/exlistq424.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exSingleSel
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
.Add("Child 2")
End With
.EndUpdate()
End With
|
423
|
How can I display no (All) item in the drop down filter window
![](images/exlistq423.png)
Dim h
With Exlist1
.BeginUpdate()
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarAll,"")
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exNoItems
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
.Add("Child 2")
End With
.EndUpdate()
End With
|
422
|
Is it possible to display no items in the drop down filter window, so only the pattern is visible
![](images/exlistq422.png)
Dim h
With Exlist1
.BeginUpdate()
With .Columns.Add("Items")
.DisplayFilterButton = True
.DisplayFilterPattern = True
.FilterList = exontrol.EXLISTLib.FilterListEnum.exNoItems
End With
With .Items
h = .Add("Root 1")
.Add("Child 1")
.Add("Child 2")
h = .Add("Root 2")
.Add("Child 1")
.Add("Child 2")
End With
.EndUpdate()
End With
|
421
|
How can I sort the value gets listed in the drop down filter window
![](images/exlistq421.png)
Dim h
With Exlist1
.MarkSearchColumn = False
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarAll,"")
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarBlanks,"")
.set_Description(exontrol.EXLISTLib.DescriptionTypeEnum.exFilterBarNonBlanks,"")
With .Columns.Add("P1")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exSortItemsDesc
End With
With .Columns.Add("P2")
.DisplayFilterButton = True
.DisplayFilterPattern = False
.FilterList = exontrol.EXLISTLib.FilterListEnum.exSortItemsAsc
End With
With .Items
h = .Add("Z3")
.set_Caption(h,1,"C")
.set_Caption(.Add("Z1"),1,"B")
.set_Caption(.Add("Z2"),1,"A")
End With
End With
|
420
|
How can I add or change the padding (spaces) for captions in the control's header
![](images/exlistq420.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Padding-Left").set_Def(exontrol.EXLISTLib.DefColumnEnum.exHeaderPaddingLeft,18)
With .Columns.Add("Padding-Right")
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exHeaderPaddingRight,18)
.HeaderAlignment = exontrol.EXLISTLib.AlignmentEnum.RightAlignment
End With
.EndUpdate()
End With
|
419
|
Do you have any plans to add cell spacing and cell padding to the cells
![](images/exlistq419.png)
With Exlist1
.BeginUpdate()
.DrawGridLines = &Hfffffffc Or exontrol.EXLISTLib.GridLinesEnum.exVLines
With .Columns.Add("Padding-Left")
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellPaddingLeft,18)
End With
.Columns.Add("No-Padding").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellHasCheckBox,True)
.Columns.Add("Empty").Position = 0
With .Items
.set_Caption(.Add("Item A.1"),1,"Item A.2")
.set_Caption(.Add("Item B.1"),1,"Item B.2")
.set_Caption(.Add("Item C.1"),1,"Item C.2")
End With
.EndUpdate()
End With
|
418
|
Is it possible display numbers in the same format no matter of regional settings in the control panel
![](images/exlistq418.png)
Dim h
With Exlist1
.BeginUpdate()
.Columns.Add("Def").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
With .Items
h = .Add(100000.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default positive)'")
h = .Add(100000.27)
.set_FormatCell(h,0,"(value format '2|.|3|,|1|1')")
h = .Add(-100000.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default negative)'")
h = .Add(-100000.27)
.set_FormatCell(h,0,"(value format '2|.|3|,|1|1')")
End With
.EndUpdate()
End With
|
417
|
Is it possible to add a 0 for numbers less than 1 instead .7 to show 0.8
![](images/exlistq417.png)
Dim h
With Exlist1
.BeginUpdate()
.Columns.Add("Def").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
With .Items
h = .Add(0.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default)'")
h = .Add(0.27)
.set_FormatCell(h,0,"(value format '|||||0') + ' <fgcolor=808080>(Display no leading zeros)'")
End With
.EndUpdate()
End With
|
416
|
How can I specify the format for negative numbers
![](images/exlistq416.png)
Dim h
With Exlist1
.BeginUpdate()
.Columns.Add("Def").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
With .Items
h = .Add(-100000.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default)'")
h = .Add(-100000.27)
.set_FormatCell(h,0,"(value format '||||1') + ' <fgcolor=808080>(Negative sign, number; for example, -1.1)'")
End With
.EndUpdate()
End With
|
415
|
Is it possible to change the grouping character when display numbers
![](images/exlistq415.png)
Dim h
With Exlist1
.BeginUpdate()
.Columns.Add("Def").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
With .Items
h = .Add(100000.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default)'")
h = .Add(100000.27)
.set_FormatCell(h,0,"(value format '|||-') + ' <fgcolor=808080>(grouping character is -)'")
End With
.EndUpdate()
End With
|
414
|
How can I display numbers with 2 digits in each group
![](images/exlistq414.png)
Dim h
With Exlist1
.BeginUpdate()
.Columns.Add("Def").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
With .Items
h = .Add(100000.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default)'")
h = .Add(100000.27)
.set_FormatCell(h,0,"(value format '||2') + ' <fgcolor=808080>(grouping by 2 digits)'")
End With
.EndUpdate()
End With
|
413
|
How can I display my numbers using a different decimal separator
![](images/exlistq413.png)
Dim h
With Exlist1
.BeginUpdate()
.Columns.Add("Def").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
With .Items
h = .Add(100.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default)'")
h = .Add(100.27)
.set_FormatCell(h,0,"(value format '|;') + ' <fgcolor=808080>(decimal separator is <b>;</b>)'")
End With
.EndUpdate()
End With
|
412
|
Is it possible to display the numbers using 3 (three) digits
![](images/exlistq412.png)
Dim h
With Exlist1
.BeginUpdate()
.Columns.Add("Def").set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
With .Items
h = .Add(100.27)
.set_FormatCell(h,0,"(value format '') + ' <fgcolor=808080>(default)'")
h = .Add(100.27)
.set_FormatCell(h,0,"(value format '3') + ' <fgcolor=808080>(3 digits)'")
h = .Add(100.27)
.set_FormatCell(h,0,"(value format 2) + ' <fgcolor=808080>(2 digits)'")
h = .Add(100.27)
.set_FormatCell(h,0,"(value format 1) + ' <fgcolor=808080>(1 digit)'")
End With
.EndUpdate()
End With
|
411
|
Is it possible to format numbers
![](images/exlistq411.png)
Dim h
With Exlist1
.BeginUpdate()
.MarkSearchColumn = False
.SelBackColor = .BackColor
.SelForeColor = .ForeColor
.ShowFocusRect = True
With .Columns
.Add("Name")
With .Add("A")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortNumeric
.AllowSizing = False
.Width = 36
.FormatColumn = "len(value) ? value + ' +'"
End With
With .Add("B")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortNumeric
.AllowSizing = False
.Width = 36
.FormatColumn = "len(value) ? value + ' +'"
End With
With .Add("C")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortNumeric
.AllowSizing = False
.Width = 36
.FormatColumn = "len(value) ? value + ' ='"
End With
With .Add("A+B+C")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortNumeric
.Width = 64
.ComputedField = "dbl(%1)+dbl(%2)+dbl(%3)"
.FormatColumn = "type(value) in (0,1) ? 'null' : ( dbl(value)<0 ? '<fgcolor=FF0000>'+ (value format '2|.|3|,|1' ) : (dbl(value)>0 ? '<fgcolor=00" & _
"00FF>+'+(value format '2|.|3|,' ): '0.00') )"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
End With
End With
With .Items
h = .Add("Item")
.set_CaptionFormat(h,4,exontrol.EXLISTLib.CaptionFormatEnum.exComputedField)
h = .Add("Item 1")
.set_Caption(h,1,7)
.set_Caption(h,2,3)
.set_Caption(h,3,1)
h = .Add("Item 2")
.set_Caption(h,1,-2)
.set_Caption(h,2,-2)
.set_Caption(h,3,-4)
h = .Add("Item 3")
.set_Caption(h,1,2)
.set_Caption(h,2,2)
.set_Caption(h,3,-4)
End With
.EndUpdate()
End With
|
410
|
Is it possible background color displayed when the mouse passes over an item
![](images/exlistq410.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Def")
.HotBackColor = Color.FromArgb(0,0,128)
.HotForeColor = Color.FromArgb(255,255,255)
With .Items
.Add("Item A")
.Add("Item B")
.Add("Item C")
End With
.EndUpdate()
End With
|
409
|
Is it possible to specify the cell's value but still want to display some formatted text instead the value
![](images/exlistq409.png)
With Exlist1
.BeginUpdate()
.MarkSearchColumn = False
With .Columns
.Add("Name")
With .Add("Values")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortNumeric
.AllowSizing = False
.Width = 64
.FormatColumn = "((0:=dbl(value)) < 10? '<fgcolor=808080><font ;7>' :'<b>') + currency(=:0)"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
End With
End With
With .Items
.set_FormatCell(.Add("Item A"),1,"`<none>`")
.set_Caption(.Add("Item 1"),1,10)
.set_Caption(.Add("Item 2"),1,15)
.set_Caption(.Add("Item 3"),1,25)
End With
.EndUpdate()
End With
|
408
|
I am using the FormatColumn to display the current currency, but would like hide some values. Is it possible
![](images/exlistq408.png)
With Exlist1
.BeginUpdate()
.MarkSearchColumn = False
With .Columns
.Add("Name")
With .Add("Values")
.SortType = exontrol.EXLISTLib.SortTypeEnum.SortNumeric
.AllowSizing = False
.Width = 64
.FormatColumn = "((0:=dbl(value)) < 10? '<fgcolor=808080><font ;7>' :'<b>') + currency(=:0)"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
End With
End With
With .Items
.set_FormatCell(.Add("Item A"),1," ")
.set_Caption(.Add("Item 1"),1,10)
.set_Caption(.Add("Item 2"),1,15)
.set_Caption(.Add("Item 3"),1,25)
End With
.EndUpdate()
End With
|
407
|
I am using the FormatColumn to format my columns. Is it possible to ignore the SelForeColor, so the foreground color for selected items does not override my settings
![](images/exlistq407.png)
' SelectionChanged event - Fired after a new item is selected.
Private Sub Exlist1_SelectionChanged(ByVal sender As System.Object) Handles Exlist1.SelectionChanged
With Exlist1
With .Items
.ClearItemBackColor(-1)
.set_ItemBackColor(.get_SelectedItem(0),Color.FromArgb(128,255,255))
End With
End With
End Sub
With Exlist1
.BeginUpdate()
.MarkSearchColumn = False
.SelForeColor = .ForeColor
.SelBackColor = .BackColor
.ShowFocusRect = False
With .Columns
With .Add("Format")
.FormatColumn = "type(value) in (0,1) ? 'null' : ( dbl(value)<0 ? '<fgcolor=FF0000>'+ (value format '2|.|3|,|1' ) : (dbl(value)>0 ? '<fgcolor=00" & _
"00FF>+'+(value format '2|.|3|,' ): '0.00') )"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
End With
End With
With .Items
.Add(10)
.Add(-8)
End With
.EndUpdate()
End With
|
406
|
Is it possible to change the height for all items at once
![](images/exlistq406.png)
With Exlist1
.BeginUpdate()
.Columns.Add("Items")
With .Items
.Add("Item 1")
.Add("Item 2")
.Add("Item 3")
.Add("Item 4")
End With
.EndUpdate()
.DefaultItemHeight = 12
.Items.set_ItemHeight(-1,12)
End With
|
405
|
How can I change the shape of the line to be shown when user drag and drop data over the control
![](images/exlistq405.png)
// OLEStartDrag event is not supported. Use the DragEnter,DragLeave,DragOver, DragDrop ... events.
With Exlist1
.OLEDropMode = exontrol.EXLISTLib.exOLEDropModeEnum.exOLEDropManual
.VisualAppearance.Add(1,"C:\Program Files\Exontrol\ExList\Sample\VB\DragDrop\insert_bottom.ebn")
.set_Background32(exontrol.EXLISTLib.BackgroundPartEnum.exListOLEDropPosition,&H1000000)
.Columns.Add("Default")
With .Items
.Add("Item 1")
.Add("Item 2")
End With
End With
|
404
|
How can I highlight the item from cursor when the user drag and drop data over the control
![](images/exlistq404.png)
// OLEStartDrag event is not supported. Use the DragEnter,DragLeave,DragOver, DragDrop ... events.
With Exlist1
.OLEDropMode = exontrol.EXLISTLib.exOLEDropModeEnum.exOLEDropManual
.set_Background(exontrol.EXLISTLib.BackgroundPartEnum.exListOLEDropPosition,Color.FromArgb(1,0,0))
.Columns.Add("Default")
With .Items
.Add("Item 1")
.Add("Item 2")
End With
End With
|
403
|
How can I start drag and drop items
![](images/exlistq403.png)
// OLEStartDrag event is not supported. Use the DragEnter,DragLeave,DragOver, DragDrop ... events.
With Exlist1
.BeginUpdate()
.OLEDropMode = exontrol.EXLISTLib.exOLEDropModeEnum.exOLEDropManual
.Columns.Add("Default")
With .Items
.Add("Item 1")
.Add("Item 2")
End With
.EndUpdate()
End With
|
402
|
When I'm trying to show string with "line break" character (vbCrLF) in a textbox, it shows 2 squares. Is there any way to hide these squares
![](images/exlistq402.png)
With Exlist1
With .Columns
.Add("Value")
With .Add("CellSingleLine = False")
.ComputedField = "%0"
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCellSingleLine,False)
End With
With .Add("FormatColumn/replace CRLF")
.ComputedField = "%0"
.FormatColumn = "value replace `\r\n` with ``"
End With
With .Add("FormatColumn/replace TAB,CRLF")
.ComputedField = "%0"
.FormatColumn = "(value replace `\t` with ``) replace `\r\n` with ``"
End With
End With
With .Items
.Add("a\ta\r\nb\tb")
End With
End With
|
401
|
The Column.Alignment property does not seem to work for cells with images in them. What can be done
![](images/exlistq401.png)
With Exlist1
.BeginUpdate()
.Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _
"lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _
"0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _
"NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
.DrawGridLines = exontrol.EXLISTLib.GridLinesEnum.exAllLines
.HeaderHeight = 24
.DefaultItemHeight = 24
With .Columns.Add("Image")
.AllowSizing = False
.Width = 32
.HTMLCaption = "<img>1</img>"
.HeaderAlignment = exontrol.EXLISTLib.AlignmentEnum.CenterAlignment
.Alignment = exontrol.EXLISTLib.AlignmentEnum.CenterAlignment
.set_Def(exontrol.EXLISTLib.DefColumnEnum.exCaptionFormat,1)
End With
.Columns.Add("Rest")
With .Items
.Add("<img>1</img>")
.Add("<img>2</img>")
.Add("<img>3</img>")
End With
.EndUpdate()
End With
|